//
//  thread_func.h
//  testpcap
//
//  Created by bugforever on 1/10/15.
//  Copyright (c) 2015 bugforever. All rights reserved.
//

#ifndef __thread_func_h
#define __thread_func_h

typedef unsigned int (* ptr_thread_func) (void * pParam);
typedef void * THREAD_HANDLE;

int create_thread( THREAD_HANDLE * ptr_thread_handle, long * ptr_thread_id, ptr_thread_func ptr_func, void * ptr_param, unsigned int flag, unsigned int stack_size );

int exit_thread();

void wait_thread_exit( THREAD_HANDLE thread_handle );

void set_thread_name( const char * str_name );

long get_current_thread_id (void);

#endif /* defined(__testpcap__thread_func__) */
